<%--
  Created by IntelliJ IDEA.
  User: jshand
  Date: 2022-10-26
  Time: 11:20
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<html>
<head>
    <title>Title</title>
</head>
<body>

<c:set var="theString" value="I am from runoob"/>

<c:if test="${fn:contains(theString, 'runoob')}">
    <p>找到 runoob<p>

</c:if>

<c:if test="${fn:contains(theString, 'RUNOOB')}">
    <p>找到 RUNOOB<p>
</c:if>


<hr>
<c:set var="theString" value="I am from runoob 123"/>

<c:if test="${fn:endsWith(theString, '123')}">
<p>字符串以 123 结尾<p>
    </c:if>

    <c:if test="${fn:endsWith(theString, 'unoob')}">
<p>字符串以 runoob 结尾<p>
    </c:if>


<hr>
<c:set var="string1" value="www runoob com"/>
<c:set var="string2" value="${fn:split(string1, ' ')}" />
<c:set var="string3" value="${fn:join(string2, '-')}" />

<p>string3 字符串 : ${string3}</p>

<c:set var="string4" value="${fn:split(string3, '-')}" />
<c:set var="string5" value="${fn:join(string4, ' ')}" />

<p>string5 字符串: ${string5}</p>




</body>
</html>
